<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2020/1/2
  Time: 12:48
  To change this template use File | Settings | File Templates.
--%>

<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head><!DOCTYPE html>
    <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
    <html>
    <head>
        <meta charset="utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/bootstrap.min.css"/>
        <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/style.css"/>
        <title>商品管理</title>
        <style type="text/css">
            th {
                text-align: center;
            }
        </style>
    </head>
<body>
<div class="container">
    <div class="row">
        <nav class="navbar navbar-default">
            <div class="container-fluid">
                <!-- Brand and toggle get grouped for better mobile display -->
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
                        <span class="sr-only">Toggle navigation</span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                    </button>

                    <a class="navbar-brand" href="#" style="font-size: 28px;">商品管理</a>
                </div>
                <!-- Collect the nav links, forms, and other content for toggling -->
                <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
                    <ul class="nav navbar-nav">
                        <li><a href="${pageContext.request.contextPath}/category/selectCategoryByPage">类别管理</a></li>
                        <li><a href="${pageContext.request.contextPath}/product/selectProducts">商品管理</a></li>
                    </ul>
                    <ul class="nav navbar-nav navbar-right">
                        <li><a href="${pageContext.request.contextPath}/exit">退出系统 <span class="czs-out-l"></span></a></li>
                    </ul>
                </div><!-- /.navbar-collapse -->
            </div><!-- /.container-fluid -->
        </nav>
    </div>
    <div class="row">
        <div class="col-md-3">

        </div>
        <div class="col-md-6">

        </div>
        <div class="col-md-3">
            <p class="bg-warning" style="">
                欢迎:[再见孙悟空] &nbsp;&nbsp;&nbsp; <img src="${pageContext.request.contextPath}/img/girl.jpg" width="50px" class="img-rounded" alt="" />
            </p>
        </div>
    </div>
    <div class="row">
        <div class="col-md-12">
            <div class="panel panel-success">
                <div class="panel-heading">
                    <h3 class="panel-title">商品名:${p.pname}</h3>
                </div>
                <div class="panel-body">
                    <table class="table">
                        <tr>
                            <td colspan="4" style="text-align: center;">
                                <img class="img-thumbnail" style="width: 50%;" src="${pageContext.request.contextPath}/img/${p.picPath}"/>
                            </td>
                        </tr>
                        <tr>
                            <td>价格:</td>
                            <td>${p.price}￥</td>
                            <td>库存:</td>
                            <td>${p.count}</td>
                        </tr>
                        <tr>
                            <td>状态:</td>
                            <c:if test="${p.status==1}">
                                <td><span class="text-success">上架</span></td>
                            </c:if>
                            <c:if test="${p.status==0}">
                                <td><span class="text-success">下架</span></td>
                            </c:if>

                            <td>上架时间:</td>
                            <td><fmt:formatDate value="${p.addDate}" pattern="yyyy-MM-dd"/></td>
                        </tr>
                        <tr>
                            <td>商品描述</td>
                            <td colspan="3">
                                ${p.pdesc}
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: center;" colspan="4">
                                <a href="${pageContext.request.contextPath}/product/selectProducts" style="text-align: center;" class="btn btn-success">
                                    <span>&lt;&lt;</span> 返回继续浏览

                                </a>
                            </td>
                        </tr>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>

</body>
</html>


